/************************************************************************/
// Copyright (C) 2016, han_gangbiao. All rights reserved.
// Use of this source code is governed by a GPL-v2 license that can be found in the License file.
// 
// [Time]:      2016-3-20 16:44:19
// [Author]:    han_gangbiao [http://my.oschina.net/jackhen]
// [Info]:      
/************************************************************************/

#ifndef INCLUDE_EXAMPLES_RPC_SERVER_H_
#define INCLUDE_EXAMPLES_RPC_SERVER_H_

#include "rpc/rpc_server_base.h"
#include "rpc/RpcServerMgr.h"

class CRPCServer : public CRpcServerBase
{
public:
    CRPCServer( CRpcServerMgr* pMgr );
private:
    virtual ~CRPCServer() { }
protected:
    virtual int on_invoke( SOCK_FD fd, smart::ref_ptr<NetBinaryPdu> pdu );
    virtual int on_rpc_close( SOCK_FD fd, int errcode );
    
};


#endif //~INCLUDE_EXAMPLES_RPC_SERVER_H_

